package com.blb.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.blb.entity.ProductHandover;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;

import java.util.Date;
import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author HuaHao
 * @since 2019-11-18
 */
public interface ProductHandoverMapper extends BaseMapper<ProductHandover> {

    /**
     * 页面数据
     * @param order_id
     * @param handoverDate
     * @return
     */
    List<ProductHandover> getList(@Param("companyId") String companyId,@Param("orderId") String order_id, @Param("handoverDate") Date handoverDate, @Param("start") int start, @Param("length") int length);

    /**
     * 查询已生产未入库的订单
     * @return
     */
    List<ProductHandover> findOrderId(String companyId);


    @Update("UPDATE t_product_handover SET state = '1'  WHERE id = #{id}")
    void updateExt(String id);

}
